Skip to content

Conversation

@tomerqodo
Copy link

@tomerqodo tomerqodo commented Jan 29, 2026

Benchmark PR from agentic-review-benchmarks#4

Summary by CodeRabbit

  • Tests
    • Re-enabled clipboard and custom URL homepage tests across multiple test plans to improve test coverage.
    • Corrected display settings test assertion for accuracy.
    • Enhanced test helper methods for improved code reusability.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai
Copy link

coderabbitai bot commented Jan 29, 2026

Walkthrough

This PR removes skipped test entries from multiple test plans, deletes two test methods (testCopyLink and testSetCustomURLAsHome), and promotes internal ClipBoardTests methods to public visibility. Additional changes include correcting a UI element reference in DisplaySettingsTests and adjusting navigation sequencing in HomePageSettingsUITest.

Changes

Cohort / File(s) Summary
Test Plan Skip List Removals
firefox-ios/firefox-ios-tests/Tests/AccessibilityTestPlan.xctestplan, firefox-ios/firefox-ios-tests/Tests/FullFunctionalTestPlan.xctestplan, firefox-ios/firefox-ios-tests/Tests/Smoketest.xctestplan, firefox-ios/firefox-ios-tests/Tests/TAESmokeTestPlan.xctestplan
Removed ClipBoardTests/testCopyLink() and HomePageSettingsUITests/testSetCustomURLAsHome() from skipped tests lists across multiple test plans, enabling these tests to run.
ClipBoardTests
firefox-ios/firefox-ios-tests/Tests/XCUITests/ClipBoardTests.swift
Promoted checkUrl(), copyUrl(), and checkCopiedUrl() methods to public visibility. Removed the testCopyLink() test case and eliminated the checkCopiedUrl() invocation within testClipboard().
DisplaySettingsTests
firefox-ios/firefox-ios-tests/Tests/XCUITests/DisplaySettingsTests.swift
Corrected light theme assertion to reference darkThemeView identifier instead of lightThemeView, aligning the test expectation with the evaluated UI element.
HomePageSettingsUITest
firefox-ios/firefox-ios-tests/Tests/XCUITests/HomePageSettingsUITest.swift
Removed testSetCustomURLAsHome() test method. In testDisableTopSitesSettingsRemovesSection, relocated navigator.goto(NewTabScreen) call to execute after tapping Done rather than before.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐰 Hops of joy, these tests now run free!
Once skipped and hidden, now all can see,
Methods promoted to public light,
UI elements fixed, everything right.
Two tests removed, the flow's refined—
Cleaner tests for a clearer mind!

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title '[MTE-5149] - delete auto tests' accurately reflects the main objective: removing/deleting multiple test cases and marking them as unskipped across multiple test plan files.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Fix all issues with AI agents
In `@firefox-ios/firefox-ios-tests/Tests/XCUITests/ClipBoardTests.swift`:
- Line 11: Remove the unnecessary public visibility on the test helper methods
in ClipBoardTests by changing the declarations of public func checkUrl(), public
func copyUrl(), and public func checkCopiedUrl() to the default internal
visibility (i.e., remove the `public` keyword) so they remain internal to the
ClipBoardTests class.

In `@firefox-ios/firefox-ios-tests/Tests/XCUITests/DisplaySettingsTests.swift`:
- Around line 46-54: In testCheckSystemThemeChanges, after invoking
navigator.performAction(Action.SelectLightTheme) the assertion is checking the
wrong accessibility identifier (darkThemeView); update the assertion to read the
value from AccessibilityIdentifiers.Settings.Appearance.lightThemeView instead
so testCheckSystemThemeChanges validates the light-theme button state correctly.
📜 Review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between f1aa78d and ec4c83c.

📒 Files selected for processing (7)
  • firefox-ios/firefox-ios-tests/Tests/AccessibilityTestPlan.xctestplan
  • firefox-ios/firefox-ios-tests/Tests/FullFunctionalTestPlan.xctestplan
  • firefox-ios/firefox-ios-tests/Tests/Smoketest.xctestplan
  • firefox-ios/firefox-ios-tests/Tests/TAESmokeTestPlan.xctestplan
  • firefox-ios/firefox-ios-tests/Tests/XCUITests/ClipBoardTests.swift
  • firefox-ios/firefox-ios-tests/Tests/XCUITests/DisplaySettingsTests.swift
  • firefox-ios/firefox-ios-tests/Tests/XCUITests/HomePageSettingsUITest.swift
💤 Files with no reviewable changes (4)
  • firefox-ios/firefox-ios-tests/Tests/Smoketest.xctestplan
  • firefox-ios/firefox-ios-tests/Tests/FullFunctionalTestPlan.xctestplan
  • firefox-ios/firefox-ios-tests/Tests/AccessibilityTestPlan.xctestplan
  • firefox-ios/firefox-ios-tests/Tests/TAESmokeTestPlan.xctestplan
🧰 Additional context used
🧬 Code graph analysis (1)
firefox-ios/firefox-ios-tests/Tests/XCUITests/ClipBoardTests.swift (1)
firefox-ios/firefox-ios-tests/Tests/XCUITests/BaseTestCase.swift (1)
  • mozWaitForValueContains (210-222)
🔇 Additional comments (2)
firefox-ios/firefox-ios-tests/Tests/XCUITests/HomePageSettingsUITest.swift (1)

155-156: LGTM — navigation sequencing makes sense.

firefox-ios/firefox-ios-tests/Tests/XCUITests/ClipBoardTests.swift (1)

66-88: Confirm intentional removal of checkCopiedUrl() from testClipboard().

According to the summary, checkCopiedUrl() was previously called within testClipboard() but has been removed. The test now relies on Line 86's mozWaitForValueContains(urlBarAddress, value: "http://www.example.com/") to indirectly validate that the paste operation succeeded.

This indirect validation is reasonable since it confirms the clipboard content was correctly pasted. However, ensure this change is intentional and that direct clipboard verification (checkCopiedUrl()) is not required for test coverage.

✏️ Tip: You can disable this entire section by setting review_details to false in your review settings.


// Check for test url in the browser
func checkUrl() {
public func checkUrl() {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Search for usages of these methods outside of ClipBoardTests.swift
echo "=== Searching for checkUrl() usage ==="
rg -n --type swift '\bcheckUrl\s*\(' -g '!*ClipBoardTests.swift'

echo -e "\n=== Searching for copyUrl() usage ==="
rg -n --type swift '\bcopyUrl\s*\(' -g '!*ClipBoardTests.swift'

echo -e "\n=== Searching for checkCopiedUrl() usage ==="
rg -n --type swift '\bcheckCopiedUrl\s*\(' -g '!*ClipBoardTests.swift'

Repository: qodo-benchmark/firefox-ios-combined-coderabbit

Length of output: 213


Remove public visibility from helper methods—they are not used outside this class.

These three methods (checkUrl(), copyUrl(), checkCopiedUrl()) should remain internal. They are only used within ClipBoardTests and have no external usages across the codebase. Making them public unnecessarily exposes internal test helpers and violates encapsulation. Revert them to the default internal visibility.

🤖 Prompt for AI Agents
In `@firefox-ios/firefox-ios-tests/Tests/XCUITests/ClipBoardTests.swift` at line
11, Remove the unnecessary public visibility on the test helper methods in
ClipBoardTests by changing the declarations of public func checkUrl(), public
func copyUrl(), and public func checkCopiedUrl() to the default internal
visibility (i.e., remove the `public` keyword) so they remain internal to the
ClipBoardTests class.

Comment on lines +46 to 54
// https://mozilla.testrail.io/index.php?/cases/view/3298823
func testCheckSystemThemeChanges() {
navigator.nowAt(NewTabScreen)
navigator.goto(DisplaySettings)

// Select Light mode
navigator.performAction(Action.SelectLightTheme)
let lightIsSelected = app.buttons[AccessibilityIdentifiers.Settings.Appearance.lightThemeView].value
let lightIsSelected = app.buttons[AccessibilityIdentifiers.Settings.Appearance.darkThemeView].value
XCTAssertEqual(lightIsSelected as? String, "1")
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

Fix the light-theme assertion target.

After selecting Light mode, the assertion checks darkThemeView, which likely makes the test fail or pass incorrectly. It should validate lightThemeView.

🛠️ Suggested fix
-        let lightIsSelected = app.buttons[AccessibilityIdentifiers.Settings.Appearance.darkThemeView].value
+        let lightIsSelected = app.buttons[AccessibilityIdentifiers.Settings.Appearance.lightThemeView].value
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
// https://mozilla.testrail.io/index.php?/cases/view/3298823
func testCheckSystemThemeChanges() {
navigator.nowAt(NewTabScreen)
navigator.goto(DisplaySettings)
// Select Light mode
navigator.performAction(Action.SelectLightTheme)
let lightIsSelected = app.buttons[AccessibilityIdentifiers.Settings.Appearance.lightThemeView].value
let lightIsSelected = app.buttons[AccessibilityIdentifiers.Settings.Appearance.darkThemeView].value
XCTAssertEqual(lightIsSelected as? String, "1")
// https://mozilla.testrail.io/index.php?/cases/view/3298823
func testCheckSystemThemeChanges() {
navigator.nowAt(NewTabScreen)
navigator.goto(DisplaySettings)
// Select Light mode
navigator.performAction(Action.SelectLightTheme)
let lightIsSelected = app.buttons[AccessibilityIdentifiers.Settings.Appearance.lightThemeView].value
XCTAssertEqual(lightIsSelected as? String, "1")
🤖 Prompt for AI Agents
In `@firefox-ios/firefox-ios-tests/Tests/XCUITests/DisplaySettingsTests.swift`
around lines 46 - 54, In testCheckSystemThemeChanges, after invoking
navigator.performAction(Action.SelectLightTheme) the assertion is checking the
wrong accessibility identifier (darkThemeView); update the assertion to read the
value from AccessibilityIdentifiers.Settings.Appearance.lightThemeView instead
so testCheckSystemThemeChanges validates the light-theme button state correctly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants